Class sjl.Bind2ndPredicate
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class sjl.Bind2ndPredicate

java.lang.Object
   |
   +----sjl.Bind2ndPredicate

public class Bind2ndPredicate
extends Object
implements Predicate1
A predicate adapter. The Bind2ndPredicate class can wrap a Predicate2 class so that it appears as a Predicate1.
    Algo.find(list.begin(), list.end(), 
              new Bind2ndPredicate(new Integer(5), new FuncLessInteger()));
The above example will return a iterator to the first element in the list with a value greater or equal to 5.

Copyright © 1996 Finn Bock


Constructor Index

 o Bind2ndPredicate(Predicate2, Object)
Specified the predicate and the value to use.

Method Index

 o compare(Object)
Call the specified predicate using value and the argument.

Constructors

 o Bind2ndPredicate
  public Bind2ndPredicate(Predicate2 pred,
                          Object val)
Specified the predicate and the value to use.

Methods

 o compare
  public boolean compare(Object o)
Call the specified predicate using value and the argument.

All Packages  Class Hierarchy  This Package  Previous  Next  Index